Skip to content

fix(bb): cache Emscripten .js / .worker.mjs siblings of .wasm targets#23122

Closed
AztecBot wants to merge 1 commit into
nextfrom
cb/b2f5e7543f61
Closed

fix(bb): cache Emscripten .js / .worker.mjs siblings of .wasm targets#23122
AztecBot wants to merge 1 commit into
nextfrom
cb/b2f5e7543f61

Conversation

@AztecBot
Copy link
Copy Markdown
Collaborator

@AztecBot AztecBot commented May 9, 2026

Superseded — same commit landed directly on #22815's branch (claudebox/a62d1521c38e34c3-3) once the cb/-prefix push guard was relaxed. Closing.

…m targets

preset_cache_paths only matched targets by name + native sibling extensions
(.exe, .node, lib*.a). Emscripten emits a .js loader and .worker.mjs pthread
worker alongside every .wasm exec target as a unit, so cache_upload missed
them and a wasm-threads cache hit restored barretenberg.wasm without the
matching barretenberg.js.

bb-ts/scripts/copy_wasm.sh then unconditionally copies cpp/build-wasm-threads/
bin/barretenberg.js into dest/<flavor>/barretenberg_wasm/, which fast-mode CI
hits before any cache miss can rebuild the cpp side, producing:
  cp: cannot stat '../cpp/build-wasm-threads/bin/barretenberg.js': No such file or directory

Extend preset_cache_paths so any target ending in .wasm also picks up the
$stem.js and $stem.worker.mjs siblings from the same bin/ directory.
@AztecBot AztecBot added the claudebox Owned by claudebox. it can push to this PR. label May 9, 2026
@AztecBot AztecBot closed this May 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

claudebox Owned by claudebox. it can push to this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant